package com.haocjia.esdemo.elastic.enums;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

public enum FieldType {

    INT(Integer.class, "long"),
    BIGDECIMAL(BigDecimal.class, "long"),
    LONG(Long.class, "long"),
    FLOAT(Float.class, "long"),
    DOUBLE(Double.class, "long"),
    BOOLEAN(Boolean.class, "boolean"),
    STRING(String.class, "text"),
    OBJECT(Object.class, "obj"),
    LIST(List.class,"list"),
    DATE(Date.class,"date"),
    ;

    private final Class<?> type;
    private final String val;

    FieldType(Class<?> type, String val) {
        this.type = type;
        this.val = val;
    }

    public Class<?> getType() {
        return type;
    }

    public String getVal() {
        return val;
    }


}
